import type { RouteRecordRaw } from 'vue-router';

const moduleName = 'check';

const routes: Array<RouteRecordRaw> = [
  {
    path: '/check',
    name: moduleName,
    redirect: '/check/record',
    meta: {
      title: '签到管理',
      icon: 'ant-design:ant-design-outlined',
    },
    children: [
      {
        path: 'record',
        name: `${moduleName}-classes`,
        meta: {
          title: '签到记录',
          icon: 'ant-design:reconciliation-filled',
        },
        component: () => import('@/views/check/record.vue'),
      },
      {
        path: 'courses',
        name: `${moduleName}-courses`,
        meta: {
          title: '请假记录',
          icon: 'ant-design:contacts-outlined',
        },
        component: () => import('@/views/check/leave.vue'),
      },
    ],
  },
];

export default routes;
